package com.yunshipei.core.model;

import android.os.Parcel;
import android.os.Parcelable;
import android.support.annotation.NonNull;

public class UrlTokenSSOModel implements Parcelable {

    private String host;
    private String params;

    public UrlTokenSSOModel(@NonNull String host, @NonNull String params) {
        this.host = host;
        this.params = params;
    }

    protected UrlTokenSSOModel(Parcel in) {
        host = in.readString();
        params = in.readString();
    }

    public static final Creator<UrlTokenSSOModel> CREATOR = new Creator<UrlTokenSSOModel>() {
        @Override
        public UrlTokenSSOModel createFromParcel(Parcel in) {
            return new UrlTokenSSOModel(in);
        }

        @Override
        public UrlTokenSSOModel[] newArray(int size) {
            return new UrlTokenSSOModel[size];
        }
    };

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeString(host);
        dest.writeString(params);
    }

    public String getHost() {
        return host;
    }

    public String getParams() {
        return params;
    }
}
